<div id="entry-list">
  <h1>Archive</h1>
  <p align="right"><%#= link_to 'Post a new entry', new_entry_path %> </p>
  <%@query = Entry.find(:all)%>

<%@hos = 0%>
<%@bums = 0%>
<%@celebs = 0%>
<%@geeks = 0%>
<%@hot = 0%>
<%@other = 0%>

<%for entry in @query%>
  <%if entry.category == 'hos'%>
    <%if @hos == 0%>
      <%@hos += 1%>
      <c1>(hos)</c1><br/>
    <%end%>
    <%= render :partial => "entries/entrybox", :locals => { :entry => entry } %>
  <%end%>
<%end%>

<%for entry in @query%>
  <%if entry.category == 'bums'%>
    <%if @bums == 0%>
      <%@bums += 1%>
      <c1>(bums)</c1><br/>
    <%end%>
    <%= render :partial => "entries/entrybox", :locals => { :entry => entry } %>
  <%end%>
<%end%>

<%for entry in @query%>
  <%if entry.category == 'celebs'%>
    <%if @celebs == 0%>
      <%@celebs += 1%>
      <c1>(celebs)</c1><br/>
    <%end%>
    <%= render :partial => "entries/entrybox", :locals => { :entry => entry } %>
  <%end%>
<%end%>

<%for entry in @query%>
  <%if entry.category == 'geeks'%>
    <%if @geeks == 0%>
      <%@geeks = 1%>
      <c1>(geeks)</c1><br/>
    <%end%>
    <%= render :partial => "entries/entrybox", :locals => { :entry => entry } %>
  <%end%>
<%end%>

<%for entry in @query%>
  <%if entry.category == 'hot'%>
    <%if @hot == 0%>
      <%@hot = 1%>
      <c1>(hot)</c1><br/>
    <%end%>
    <%= render :partial => "entries/entrybox", :locals => { :entry => entry } %>
  <%end%>
<%end%>

<%for entry in @query%>
  <%if entry.category == 'other'%>
    <%if @other == 0%>
      <%@other = 1%>
      <c1>(other)</c1><br/>
    <%end%>
    <%= render :partial => "entries/entrybox", :locals => { :entry => entry } %>
  <%end%>
<%end%>

</div>